<template>
    <c-pdf @closepdf="closepdf" v-model="isshowpdf" :pdfurl="pdfurls" @pdferr="pdferr" :maxscale='4' :minscale='0.6' :scale='1.1' ></c-pdf>
</template>

<script>
import request from "../../config/request.js"
import {bus} from "../../config/bus.js"
import CPdf from '../../components/pdf.vue';
export default {
    data(){
        return{
             pdfurls:'',
             isshowpdf:true
        }
    },
    components: {
      CPdf
    },
    created(){
    	let self = this;
//  	request.getProtocolInvest({'userItemId':this.$route.params.userItemId},function(res){
//  		self.pdfurls = '/fish-backend/pdf/'+ res.data;
//  	});
		//self.pdfurls = '/fish-backend/pdf/yht/201803221134320000001000123820.pdf';
		self.pdfurls = decodeURI(this.$route.params.urlMsg);
		//self.pdfurls = decodeURI(this.$route.params.urlMsg);
    },
    mounted(){

    },
    methods:{
        closepdf(){
            this.isshowpdf = false
        },
        pdferr(errurl) {
            console.log(errurl);
        }
    }
 }
</script>